package object.library.user;

import object.library.operation.*;

import java.util.Scanner;

public class NormalUser extends User {
    public NormalUser(String name) {
        super(name);

        operations = new IOperation[]{
                new ExitOperation(),
                new ListOperation(),
                new FindOperation(),
                new BorrowOperation(),
                new ReturnOperation(),
        };
    }

    @Override
    public int menu(){
        System.out.println("----------------------------------");
        System.out.println("Welcome Admin " + name + "!");
        System.out.println("1. 查看书籍列表");
        System.out.println("2. 按名字查找书籍");
        System.out.println("3. 借阅书籍");
        System.out.println("4. 归还图书");
        System.out.println("0. 退出系统");
        System.out.println("----------------------------------");
        System.out.print("请输入您的选择：");
        Scanner scanner = new Scanner(System.in);
        int choice = scanner.nextInt();
        return choice;

    }
}
